import { defineConfig } from '@soybeanjs/eslint-config'

export default defineConfig(
  { vue: true, unocss: true },
  {
    rules: {
      'vue/multi-word-component-names': 'off',
      'vue/require-v-for-key': 'off', //
      'vue/component-name-in-template-casing': [
        'warn',
        'kebab-case',
        {
          registeredComponentsOnly: false,
          ignores: ['/^icon-/'],
        },
      ],
      'unocss/order-attributify': 'off',
      'order-attributify': 'off',
      'no-plusplus': 'off',
      'no-underscore-dangle': 'off',
      'no-multi-assign': 'off',
      'no-bitwise': 'off',
      'no-param-reassign': 'off',
      'no-continue': 'off',
      'no-sequences': 'off',
      'no-await-in-loop': 'off',
      'no-useless-escape': 'off',
      'no-unsafe-optional-chaining': 'off',
      'n/prefer-global/process': 'off',
      '@typescript-eslint/no-this-alias': 'off',
      '@typescript-eslint/no-shadow': 'off',
      '@typescript-eslint/no-unused-vars': 'off',
      '@typescript-eslint/no-use-before-define': 'off',
      '@typescript-eslint/ban-ts-comment': 'off',
      '@typescript-eslint/no-dynamic-delete': 'off',
      '@typescript-eslint/no-invalid-void-type': 'off',
      '@typescript-eslint/no-unused-expressions': 'off',
      'consistent-return': 'off',
      'consistent-this': 'off',
      'prefer-promise-reject-errors': 'off',
      'vue/no-undef-properties': 'off',
      'vue/no-unused-properties': 'off',
      'vue/no-duplicate-attr-inheritance': 'off',
      'vue/no-required-prop-with-default': 'off',
      'vue/no-v-text-v-html-on-component': 'off',
      'vue/no-static-inline-styles': 'off',
      'vue/require-default-prop': 'off',
      'vue/define-props-declaration': 'off',
      'vue/define-emits-declaration': 'off',
      'vue/no-unused-emit-declarations': 'off',
      'vue/prefer-import-from-vue': 'off',
      'vue/require-prop-types': 'off',
      'vue/prefer-true-attribute-shorthand': 'off',
      '@typescript-eslint/no-var-requires': 'off',
      'logical-assignment-operators': 'off',
      'max-params': 'off',
      'vue/no-dupe-keys': 'off',
      'no-console': 'off',
      'no-nested-ternary': 'off',
      'vue/no-v-html': 'off',
      'no-new-func': 'off',
      'no-invalid-this': 'off',
      'no-async-promise-executor': 'off',
      'class-methods-use-this': 'off',
      'func-names': 'off',
      'no-prototype-builtins': 'off',
      'vue/first-attribute-linebreak': [
        2,
        {
          singleline: 'beside',
          multiline: 'below',
        },
      ],
      'vue/max-attributes-per-line': [
        2,
        {
          singleline: 6,
          multiline: {
            max: 1,
          },
        },
      ],
      complexity: ['error', { max: 100 }],
    },
  },
)
